import mock from 'mockjs'
const { shop } = mock.mock({
    "shop|100": [{
        "title": "@ctitle(5,10)",
        "image": "@image(50x50,@color)",
        "price|1-1000": 1,
        "type|1-10": 1,
        "id": "@id"
    }]
})
const { type } = mock.mock({
    "type|10": [{
        "title": "@ctitle(5,10)",
        "children|10": [{
            "title": "@ctitle(5,10)",
            "parent_id|1-10": 1,
            "children|10": [{
                "title": "@ctitle(5,10)",
                "parent_id|1-10": 1,
                "image": "@image(50x50,@color)",
            }]
        }]
    }]
})

mock.mock('/shop', shop) // 商品数据
mock.mock('/type', type) // 分类数据